package com.youhome.service.impl;

import com.youhome.mapper.HouseTranslateMapper;
import com.youhome.model.HouseTranslate;
import com.youhome.service.HouseTranslateService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Date;

/**
 * Created by chen365 on 2017/9/18.
 */
@Service
public class HouseTranslateServiceImpl implements HouseTranslateService {
    @Autowired
    private HouseTranslateMapper mapper;

    @Override
    public int insertSelective(HouseTranslate record) {
        record.setStatus(1);
        record.setCtime(new Date());
        return mapper.insertSelective(record);
    }

    @Override
    public HouseTranslate selectByPrimaryKey(Long id) {
        return mapper.selectByPrimaryKey(id);
    }


    @Override
    public HouseTranslate selectByHouseId(String houseId){
        return mapper.selectByHouseId(houseId);
    }
}
